﻿package
{
    public class MessageDS
    {
        public var type:int;
        public var userID:String;
        public var recipientIDs:Array;
        public var mess:String;
        public var timestamp:String;
        
        public function MessageDS(type:int, user:String, recip:Array, rmess:String, time:String)
        {
            this.type = type;
            userID = user;
            recipientIDs = recip;
            mess = rmess;
            timestamp = time;
        }
    
        public function setType(type:int)
        {
            this.type = type;
        }
        
        public function setTimeStamp(ts:String)
        {
            this.timestamp = ts;
        }
        
        public function getTimeStamp():String
        {
            return timestamp;
        }
        
        public function getType():int
        {
            return type;
        }
        
        public function setRecipientIDs(recpIDs:Array)
        {
            this.recipientIDs = recpIDs;
        }
        
        public function addRecipientID(recipID:String)
        {
            this.recipientIDs.push(recipID);
        }
        
        public function setMess(mess:String)
        {
            this.mess = mess;
        }
        
        public function setUserID(userID:String)
        {
            this.userID = userID;
        }
          
        public function getUserID():String
        {
            return userID;
        }
        
        public function getRecipientIDs(): Array
        {
            return recipientIDs;
        }
        
        public function getMess(): String
        {
            return mess;
        }
    }
}